<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <style>
        /*id选择器*/
        #p1{color: red}
        /*类选择器*/
        .c1{color: blue}
        /*分组选择器*/
        #p1,.c1,h3{background-color: yellow}
        /*属性选择器*/
        input[type='text']{background-color: green}
        /*任意元素选择器*/
        *{border: 1px solid red}
    </style>
</head>
<body>
<input type="text">
<input type="password">
<p id="p1">悟空</p>
<p>八戒</p>
<p class="c1">沙僧</p>
<div>苹果</div>
<div>香蕉</div>
<div class="c1">橘子</div>
<h3>这是h3</h3>
</body>
</html>